<%@ page contentType="text/html; charset=UTF-8"%>
<%@ include file="/WEB-INF/jsp/common/init.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<jsp:include page="/WEB-INF/jsp/common/common.jsp" />
<script type="text/javascript">
	function query() {
		$("#form1").submit();
	}
	function myAdd() {
		var url = "${path}/ix/role/add_form.htm";
		$("#form1").attr("action", url);
		$("#form1").submit();
	}
	function goDetail(role_id) {
		$("input[name='role_id']").val(role_id);

		var url = "${path}/ix/role/edit_form.htm";
		$("#form1").attr("action", url);
		$("#form1").submit();
	}
	function goDel(role_id) {
		$("input[name='role_id']").val(role_id);

		var url = "${path}/ix/role/del.htm";
		$("#form1").attr("action", url);
		$("#form1").submit();
	}
</script>
</head>
<body>
	<jsp:include page="/WEB-INF/jsp_lib/tip.jsp" />
	<div>
		<form action="${path}/ix/role/list.htm" id="form1" method="post">
			<input type="hidden" name="role_id" />
			<h2>
				<div>权限管理</div>
				<!-- <span><a href="javascript:myAdd();" class="aadd">【添加】</a></span> -->
			</h2>
			<!--<div class="query">
				<table width="100%" border="0" align="center" cellpadding="0" cellspacing="5">
				 <tr>
						<td width="60" align="right">
							<strong>标题：</strong>
						</td>
						<td width="200" align="left">
							<input name="srh_name" type="text" /> 
						</td>
						<td align="left">
							<a href="javascript:query();">
								<img src="${path}/style_cp/img/query.jpg" name="Image4" width="85" height="27" border="0" id="Image4" /> 
							</a>
						</td>
					</tr>
				
				</table>
			</div>-->

			<table width="100%" class="listlindex">
				<tr>
					<th>角色名称</th>
					<th>角色描述</th>
					<th>操作</th>
				</tr>
				<c:if test="${fn:length(list)==0}">
					<tr>
						<td colspan="3"><div class="tip_div">暂无记录.</div></td>
					</tr>
				</c:if>
				<c:forEach items="${list}" var="v">
					<tr>
						<td>${v.name}</td>
						<td>${v.note}</td>
						<td><a href="javascript:goDetail('${v._id}');">【修改】</a> <a
							href="javascript:goDel('${v._id}');">【删除】</a></td>
					</tr>
				</c:forEach>
			</table>
			<div id="response"></div>
			<div class="options">
				<p>
					<a href="javascript:myAdd();">【添加】</a>
				</p>
				<div class="quotes">
					<!-- <page:page page="${page}" /> -->
				</div>
				<div class="clear"></div>
			</div>
		</form>

	</div>
</body>
</html>